home *** CD-ROM | disk | FTP | other *** search
- Name
-
- SGI_make_current_read
-
- Name Strings
-
- GLX_SGI_make_current_read
-
- Version
-
- $Date: 1995/09/30 02:31:42 $ $$
-
- Number
-
- 42
-
- Dependencies
-
- EXT_copy_texture is affected by this specification.
- EXT_convolution is affected by this specification.
- SGI_color_table is affected by this specification.
-
- Overview
-
- The association of the current context with a drawable is extended to allow
- separate write and read drawables.
-
- New Procedures and Functions
-
- Bool glXMakeCurrentReadSGI(Display* dpy,
- GLXDrawable draw,
- GLXDrawable read,
- GLXContext ctx);
-
- GLXDrawable glXGetCurrentReadDrawableSGI(void);
-
- New Tokens
-
- None
-
- Additions to Chapter 2 of the 1.0 Specification (OpenGL Operation)
-
- None
-
- Additions to Chapter 3 of the 1.0 Specification (Rasterization)
-
- None
-
- Additions to Chapter 4 of the 1.0 Specification (Per-Fragment Operations
- and the Frame buffer)
-
- If glXMakeCurrentReadSGI is used to associate two glXDrawables with
- the current rendering context, glXDrawable <draw> is used for all
- OpenGL operation except:
-
- 1. Any pixel data that are sourced based on the value of glReadBuffer.
-
- 2. Any depth values that are retrieved by glReadPixels, glCopyPixels,
- or any OpenGL extension that sources depth images from the frame
- buffer in the manner of glReadPixels and glCopyPixels.
-
- 3. Any stencil values that are retrieved by glReadPixels, glCopyPixels,
- or any OpenGL extension that sources stencil images from the frame
- buffer in the manner of glReadPixels and glCopyPixels.
-
- These frame buffer values are taken from glXDrawable <read>.
-
- No error will be generated if the value of READ_BUFFER at the time the
- glXMakeCurrentReadSGI call is made does not correspond to a valid color
- buffer in <read>. Also, no error due to READ_BUFFER mismatch will be
- generated by subsequent calls to any of the operations enumerated above,
- but the pixels values used will be undefined until READ_BUFFER is set to a
- color buffer that is valid in the <read>. Operations that query the value
- of READ_BUFFER (i.e., glGet, glPushAttrib) use the value set last in the
- context, independent of whether it is a valid buffer in <read>.
- Subsequent to a glXMakeCurrentRead call, it is possible that the
- READ_BUFFER may be set to a color buffer that is not valid with respect to
- the visual of the context. The preceding discussion also applies to
- glXMakeCurrent where <read> is replaced by the single drawable parameter
- to the call.
-
- Error conditions set by glDrawBuffer (even when called implicitly via
- glPopAttrib) and by the operations enumerated above are with respect to
- color and ancillary buffers available in <read> (i.e.,
- glReadBuffer(GL_BACK_BUFFER) will generate an error when <read> is single
- buffered, and so will an operation that tries to source stencil images
- when <read> does not have a stencil buffer).
-
- Additions to Chapter 5 of the 1.0 Specification (Special Functions)
-
- None
-
- Additions to Chapter 6 of the 1.0 Specification (State and State Requests)
-
- None
-
- Additions to the GLX Specification
-
- XXX - not complete yet
-
- Notes:
-
- * glXMakeCurrentReadSGIX associates two GLXDrawables with a single
- GLXContext. BadMatch is generated if <draw> was not created with
- the same X screen and visual as <ctx>. BadMatch is also generated
- if <read> was not created with the same X screen as <ctx>. The
- only requirement for the visual type of <read>, however, is that it
- be an RGBA, as opposed to index, visual. Its color, depth, stencil,
- and accumulation buffers need not match the resources of <draw>.
-
- * glXMakeCurrentReadSGI returns True if it succeeds, and False if it
- fails. It can fail for myriad reasons, including refusal to accept
- a window or a GLXPixmap as the <read> GLXDrawable, and refusal to
- accept as the <read> GLXDrawable or a GLXPbuffer with color, depth,
- stencil, or accumulation storage facilities that differ from those
- of <draw>. This laxness may not be acceptable in a final
- specification, but it will help allow early implementations to
- be completed.
-
- * glXGetCurrentReadDrawableSGI returns the name of the GLXDrawable
- currently being used as a pixel query source. If glXMakeCurrent
- specified the current rendering context, then
- glXGetCurrentReadDrawableSGI returns the drawable specified as
- <draw> by that glXMakeCurrent call. If glXMakeCurrentReadSGI
- specified the current rendering context, then
- glXGetCurrentReadDrawableSGI returns the drawable specified as
- <read> by that glXMakeCurrentReadSGI call. If there is no
- current read drawable, None is returned.
-
- Dependencies on EXT_copy_texture
-
- Texture image data are sourced from GLXDrawable <read> if the
- current OpenGL rendering context was specified by glXMakeCurrentReadSGIX.
-
- Dependencies on EXT_convolution
-
- Convolution image data are sourced from GLXDrawable <read> if the
- current OpenGL rendering context was specified by glXMakeCurrentReadSGIX,
- and the transfer is specified by CopyConvolutionFilter1DEXT or
- CopyConvolutionFilter2DEXT.
-
- Dependencies on SGI_color_table
-
- Color table data are sourced from GLXDrawable <read> if the current
- OpenGL rendering context was specified by glXMakeCurrentReadSGIX,
- and the transfer is specified by CopyColorTableSGI.
-
- New State
-
- None
-
- New Implementation Dependent State
-
- None
-